package com.chy.service.impl;

import com.chy.bean.Gallery;
import com.chy.bean.Order;
import com.chy.dao.OrderDao;
import com.chy.service.OrderService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
@Service("orderService")
public class OrderServiceImpl implements OrderService {
    @Autowired
    private OrderDao orderDao;

    @Override
    public List<Order> getAll() {
       return orderDao.getAll();
    }

    @Override
    public void delete(Order order) {
        orderDao.delete(order);
    }

    @Override
    public void add(Order order,String addImgId) {
        orderDao.add(order,addImgId);
    }

    @Override
    public void update(Order order,String updateImgId) {
        orderDao.update(order,updateImgId);
    }

    @Override
    public void uploading(String name) {
        orderDao.uploading(name);
    }

    @Override
    public List<Gallery> getAllImg() {
        return orderDao.getAllImg();
    }
}
